# @Time : 2025-03-26 14:51
# @Author : Fioman 
# @Phone : 13149920693
"""
将框架进行抽离
"""
import sys

from PySide6 import QtWidgets
from PySide6.QtCore import Qt


class MainView(QtWidgets.QWidget):
    def __init__(self, *args, **kwargs):
        super(MainView, self).__init__(*args, **kwargs)
        self.setWindowTitle("抽离框架")
        self.resize(500, 500)
        self.setup_main_view_ui()

    def setup_main_view_ui(self):
        """"
        设置主界面UI界面
        """
        # 1. 先创建一个垂直布局
        self.layout = QtWidgets.QVBoxLayout(self)
        self.layout.setAlignment(Qt.AlignmentFlag.AlignCenter)

        # 2. 创建一个按钮
        self.button = QtWidgets.QPushButton("按钮")
        self.button.setFixedSize(100, 30)

        self.layout.addWidget(self.button)


if __name__ == '__main__':
    app = QtWidgets.QApplication([])
    mainView = MainView()
    mainView.show()
    sys.exit(app.exec())
